package com.groupscore.score.controller;

import com.groupscore.score.pojo.UserException;
import com.groupscore.score.service.ExcepitionCatService;
import com.groupscore.score.service.TeamService;
import com.groupscore.score.service.UserExcepitionService;
import entity.Result;
import entity.StatusCode;
import io.jsonwebtoken.Claims;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.data.redis.core.RedisTemplate;
import org.springframework.web.bind.annotation.*;
import util.JwtUtil;

import javax.servlet.http.HttpServletRequest;
import java.util.HashMap;
import java.util.Map;


@RestController
@RequestMapping("/exceptionCat")
public class ExceptionCatController {

    @Autowired
    private ExcepitionCatService excepitionCatService;

    @Autowired
    private JwtUtil jwtUtil;



    /**
     * 查询所有分类
     * @return
     */
    @CrossOrigin
    @GetMapping("/findAll")
    public Result findAll(){
        return  new Result(true, StatusCode.OK, "查询成功",excepitionCatService.findAll());
    }

}
